﻿@{
    ViewBag.Title = "Home Page";
}
@using Shumei.EFCore.Model
@using System.Collections.Generic
<!DOCTYPE html>
<html>
<head>
    <meta name="viewport"  />
    @Styles.Render("~/Content/css/index.css")
    @Styles.Render("~/Content/css/reset.css")
    @Scripts.Render("~/Content/js/jquery-min-inedx.js")
    @Scripts.Render("~/Content/js/index.js")

    <title></title>
</head>
<body>
    <!-- 精彩推荐 -->
    <div class="main" id="recommend">
        <div class="main-inner">
            @*<div class="main-title">
                <h2 class="title"><i></i></h2>
                <span class="line line-left"></span>
                <span class="line line-right"></span>
            </div>*@
            <div class="carousel">
                <div class="carousel-slider">
                    @{
                        List<Course> courses = (List<Course>)ViewData["courses"];
                        for (int i = 0; i < courses.Count; i++)
                        {
                            <a href="#" class="item item-pic@(i)"><img src="@Url.Content(courses[i].CourseIcon)" alt="#"></a>
                        }
                        
                    }

                    @*<a href="#" class="item item-pic1"><img src="@Url.Content("~/Content/Images/cont/carousel_img1.jpg")" alt="#"></a>
                    <a href="#" class="item item-pic2"><img src="@Url.Content("~/Content/Images/cont/carousel_img2.jpg")" alt="#"></a>
                    <a href="#" class="item item-pic3"><img src="@Url.Content("~/Content/Images/cont/carousel_img3.jpg")" alt="#"></a>
                    <a href="#" class="item item-pic4"><img src="@Url.Content("~/Content/Images/cont/carousel_img4.jpg")" alt="#"></a>
                    <a href="#" class="item item-pic5"><img src="@Url.Content("~/Content/Images/cont/carousel_img5.jpg")" alt="#"></a>
                    <a href="#" class="item item-pic6"><img src="@Url.Content("~/Content/Images/cont/carousel_img6.jpg")" alt="#"></a>*@
                </div>
                <div class="slider-btns">
                    <span class="cur"><i></i></span>
                    @for (int i = 0; i < courses.Count - 1; i++)
                    {
                        <span><i></i></span>
                    }
                    @*<span><i></i></span>
                    <span><i></i></span>*@
                </div>
            </div>
        </div>
        <div class="main-operate">
            <a href="#" class="slider-prev"><i class="icon-sprite"></i></a>
            <a href="#" class="slider-next"><i class="icon-sprite"></i></a>
        </div>
    </div>

    <!-- 最新课程 -->
    <div class="main" id="mv">
        <div class="main-inner">
            <div class="main-title">
                <h2 class="title"><i></i></h2>
                <span class="line line-left"></span>
                <span class="line line-right"></span>
            </div>
            <a href="#" class="readAll">全部<i class="icon-sprite"></i></a>
            <div class="main-tab tab-title">
            </div>
            <ul class="mv-list tab-cont">
               @{
                   var lastCourse = (List<Course>)ViewData["lastCourse"];
                   for (int i = 0; i < lastCourse.Count; i++)
                    {
                        <li class="item">
                            <a href="@Url.Action("Course", "Course", new { CourseId = lastCourse[i].Id })" class="img">
                                <img src="@Url.Content(lastCourse[i].CourseIcon)" alt="#">
                                <i class="icon-play"></i>
                            </a>
                            <div class="info">
                                <a href="@Url.Action("Course", "Course", new { CourseId = lastCourse[i].Id })" class="title">@lastCourse[i].Name</a>
                                <a href="@Url.Action("Course", "Course", new { CourseId = lastCourse[i].Id })" class="author">@lastCourse[i].Teacher.name</a>
                                @*<span class="play-total"><i class="icon-sprite"></i>18.8万</span>*@
                            </div>
                        </li>
                    }

                }
            </ul>
        </div>
    </div>

    <!-- NEWS -->
    <div class="main" id="mv">
        <div class="main-inner">
            <div class="main-title">
                <h2 class="title"><i></i></h2>
                <span class="line line-left"></span>
                <span class="line line-right"></span>
            </div>
            <a href="@Url.Action("News","News")" class="readAll">全部<i class="icon-sprite"></i></a>
            <div class="main-tab tab-title">
            </div>
            <div class="rt-section-body">
                <ul class="rt-article-list clearfix">
                    @{
                        List<New> news = (List<New>)ViewData["news"];
                        for (int i = 0; i < news.Count; i++)
                        {
                            <li class="text-overflow">
                                
                                <span class="date">[@news[i].UploadTime.Month-@news[i].UploadTime.Day]</span>
                                <a href="@Url.Action("NewDetail", "News", new { NewsId = news[i].Id })" class="link-dark">
                                    @news[i].Title
                                </a>
                            </li> 
                        }
                    }
                </ul>
            </div>

        </div>
    </div>
    <!-- GAME -->
    <div class="main" id="game">
        <div class="main-inner">
            <div class="main-title">
                <h2 class="title"><i></i></h2>
                <span class="line line-left"></span>
                <span class="line line-right"></span>
            </div>
            <a href="#" class="readAll">全部<i class="icon-sprite"></i></a>
            <div class="main-tab tab-title">
            </div>
            <ul class="game-list tab-cont">
                @{
                    var gameCourse = (List<Course>)ViewData["gameCourse"];
                    for (int i = 0; i < gameCourse.Count; i++)
                    {
                        <li class="item">
                            <a href="@Url.Action("Course", "Course", new { CourseId = gameCourse[i].Id })" class="img"><img src="@Url.Content(gameCourse[i].CourseIcon)" alt="#">
                                <i class="icon-play"></i>
                            </a>
                            <div class="info">
                                <a href="@Url.Action("Course", "Course", new { CourseId = gameCourse[i].Id })" class="title">@gameCourse[i].Name</a>
                                <a href="@Url.Action("Course", "Course", new { CourseId = gameCourse[i].Id })" class="author">@gameCourse[i].Teacher.name</a>
                                @*<span class="play-total"><i class="icon-sprite"></i>18.8万</span>*@
                            </div>
                    </li>
                    }
                    
                }
                
            </ul>
        </div>
    </div>

    <!-- CARTOON -->
    <div class="main" id="cartoon">
        <div class="main-inner">
            <div class="main-title">
                <h2 class="title"><i></i></h2>
                <span class="line line-left"></span>
                <span class="line line-right"></span>
            </div>
            <a href="#" class="readAll">全部<i class="icon-sprite"></i></a>
            <div class="main-tab tab-title">
            </div>
            <ul class="cartoon-list tab-cont">
                @{
                    var cartoonCourse = (List<Course>)ViewData["cartoonCourse"];
                    for (int i = 0; i < cartoonCourse.Count; i++)
                    {
                        <li class="item">
                            <a href="@Url.Action("Course", "Course", new { CourseId = gameCourse[i].Id })" class="img"><img src="@Url.Content(gameCourse[i].CourseIcon)" alt="#"><i class="icon-play"></i></a>
                            <div class="info">
                                <a href="@Url.Action("Course", "Course", new { CourseId = gameCourse[i].Id })" class="title">@cartoonCourse[i].Name</a>
                                <a href="@Url.Action("Course", "Course", new { CourseId = gameCourse[i].Id })" class="author">@cartoonCourse[i].Teacher.name</a>
                                @*<span class="play-total"><i class="icon-sprite"></i>18.8万</span>*@
                            </div>
                        </li>
                    }

                }
            </ul>
        </div>
    </div>

    <!-- 作品展示 -->
    <div class="main" id="hotSong">
        <div class="main-inner">
            <div class="main-title">
                <h2 class="title"><i></i></h2>
                <span class="line line-left"></span>
                <span class="line line-right"></span>
            </div>
            <div class="main-slider">
                <ul class="slider-wrapper">
                    <li>
                        <a href="#" class="img">
                            <img src="@Url.Content("~/Content/Images/cont/slider_img1.jpg")" alt="#">
                            <span class="mask"></span>
                            <i class="icon-play"></i>
                        </a>
                        <div class="info">
                            <div class="title">
                                <!-- <a href="#">那个静默的阳光午后</a> -->
                                <a href="#">殿堂金钻认证：BIGBANG最热歌曲大合集</a>
                                <i class="icon-sprite"></i>
                            </div>
                            <a href="#" class="author">播放量：179.7万</a>
                        </div>
                    </li>
                    <li>
                        <a href="#" class="img">
                            <img src="@Url.Content("~/Content/Images/cont/slider_img2.jpg")" alt="#">
                            <span class="mask"></span>
                            <i class="icon-play"></i>
                        </a>
                        <div class="info">
                            <div class="title">
                                <a href="#">那个静默的阳光午后</a>
                                <i class="icon-sprite"></i>
                            </div>
                            <a href="#" class="author">播放量：179.7万</a>
                        </div>
                    </li>
                    <li>
                        <a href="#" class="img">
                            <img src="@Url.Content("~/Content/Images/cont/slider_img1.jpg")" alt="#">
                            <span class="mask"></span>
                            <i class="icon-play"></i>
                        </a>
                        <div class="info">
                            <div class="title">
                                <a href="#">那个静默的阳光午后</a>
                                <i class="icon-sprite"></i>
                            </div>
                            <a href="#" class="author">播放量：179.7万</a>
                        </div>
                    </li>
                    <li>
                        <a href="#" class="img">
                            <img src="@Url.Content("~/Content/Images/cont/slider_img1.jpg")" alt="#">
                            <span class="mask"></span>
                            <i class="icon-play"></i>
                        </a>
                        <div class="info">
                            <div class="title">
                                <a href="#">那个静默的阳光午后</a>
                                <i class="icon-sprite"></i>
                            </div>
                            <a href="#" class="author">播放量：179.7万</a>
                        </div>
                    </li>
                    <li>
                        <a href="#" class="img">
                            <img src="@Url.Content("~/Content/Images/cont/slider_img1.jpg")" alt="#">
                            <span class="mask"></span>
                            <i class="icon-play"></i>
                        </a>
                        <div class="info">
                            <div class="title">
                                <a href="#">那个静默的阳光午后</a>
                                <i class="icon-sprite"></i>
                            </div>
                            <a href="#" class="author">播放量：179.7万</a>
                        </div>
                    </li>
                    <li>
                        <a href="#" class="img">
                            <img src="@Url.Content("~/Content/Images/cont/slider_img1.jpg")" alt="#">
                            <span class="mask"></span>
                            <i class="icon-play"></i>
                        </a>
                        <div class="info">
                            <div class="title">
                                <a href="#">那个静默的阳光午后</a>
                                <i class="icon-sprite"></i>
                            </div>
                            <a href="#" class="author">播放量：179.7万</a>
                        </div>
                    </li>
                    <li>
                        <a href="#" class="img">
                            <img src="@Url.Content("~/Content/Images/cont/slider_img1.jpg")" alt="#">
                            <span class="mask"></span>
                            <i class="icon-play"></i>
                        </a>
                        <div class="info">
                            <div class="title">
                                <a href="#">那个静默的阳光午后</a>
                                <i class="icon-sprite"></i>
                            </div>
                            <a href="#" class="author">播放量：179.7万</a>
                        </div>
                    </li>
                    <li>
                        <a href="#" class="img">
                            <img src="@Url.Content("~/Content/Images/cont/slider_img1.jpg")" alt="#">
                            <span class="mask"></span>
                            <i class="icon-play"></i>
                        </a>
                        <div class="info">
                            <div class="title">
                                <a href="#">那个静默的阳光午后</a>
                                <i class="icon-sprite"></i>
                            </div>
                            <a href="#" class="author">播放量：179.7万</a>
                        </div>
                    </li>
                    <li>
                        <a href="#" class="img">
                            <img src="@Url.Content("~/Content/Images/cont/slider_img1.jpg")" alt="#">
                            <span class="mask"></span>
                            <i class="icon-play"></i>
                        </a>
                        <div class="info">
                            <div class="title">
                                <a href="#">那个静默的阳光午后</a>
                                <i class="icon-sprite"></i>
                            </div>
                            <a href="#" class="author">播放量：179.7万</a>
                        </div>
                    </li>
                    <li>
                        <a href="#" class="img">
                            <img src="@Url.Content("~/Content/Images/cont/slider_img1.jpg")" alt="#">
                            <span class="mask"></span>
                            <i class="icon-play"></i>
                        </a>
                        <div class="info">
                            <div class="title">
                                <a href="#">那个静默的阳光午后</a>
                                <i class="icon-sprite"></i>
                            </div>
                            <a href="#" class="author">播放量：179.7万</a>
                        </div>
                    </li>
                    <li>
                        <a href="#" class="img">
                            <img src="@Url.Content("~/Content/Images/cont/slider_img1.jpg")" alt="#">
                            <span class="mask"></span>
                            <i class="icon-play"></i>
                        </a>
                        <div class="info">
                            <div class="title">
                                <a href="#">那个静默的阳光午后</a>
                                <i class="icon-sprite"></i>
                            </div>
                            <a href="#" class="author">播放量：179.7万</a>
                        </div>
                    </li>
                    <li>
                        <a href="#" class="img">
                            <img src="@Url.Content("~/Content/Images/cont/slider_img1.jpg")" alt="#">
                            <span class="mask"></span>
                            <i class="icon-play"></i>
                        </a>
                        <div class="info">
                            <div class="title">
                                <a href="#">那个静默的阳光午后</a>
                                <i class="icon-sprite"></i>
                            </div>
                            <a href="#" class="author">播放量：179.7万</a>
                        </div>
                    </li>
                </ul>
                <div class="slider-btns">
                    <span class="cur"><i></i></span>
                    <span><i></i></span>
                    <span><i></i></span>
                </div>
            </div>
        </div>
        <div class="main-operate">
            <a href="javascript:;" class="slider-prev"><i class="icon-sprite"></i></a>
            <a href="javascript:;" class="slider-next"><i class="icon-sprite"></i></a>
        </div>
    </div>
    
  
    

</body>
@RenderPage("~/Views/Shared/footerPage.cshtml")
 
</html>
